﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using iPhoneTrackerWin.Data;

namespace iPhoneTrackerWin.Parser
{
    public class GPXObject
    {
        /// <summary>
        /// Alle Tracks von diesem GPX Objekt
        /// </summary>
        public List<Track> Tracks { get; set; }

        /// <summary>
        /// Alle Routen von diesem GPX Objekt
        /// </summary>
        public List<Route> Routes { get; set; }

        /// <summary>
        /// Alle einfachen "Waypoints" dieser GPX
        /// </summary>
        public List<GPS> Points { get; set; }

        public GPXObject()
        {
            Tracks = new List<Track>();
            Routes = new List<Route>();
            Points = new List<GPS>();
        }

        /// <summary>
        /// Fügt einen Track dem Objekt hinzu
        /// </summary>
        /// <param name="t"></param>
        public void addTrack(Track t)
        {
            Tracks.Add(t);
        }

        /// <summary>
        /// Fügt eine Route hinzu
        /// </summary>
        /// <param name="r"></param>
        public void addRoute(Route r)
        {
            Routes.Add(r);
        }

        /// <summary>
        /// Füg einen Waypoint hinzu
        /// </summary>
        /// <param name="g"></param>
        public void addPoint(GPS g)
        {
            Points.Add(g);
        }
    }
}
